/* 
 * Copyright (c) 2008 Knightsoft
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *   http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
*/
package com.knightsoft.util;

import java.io.PrintStream;

/**
 * Print methods that can be used without
 * qualifiers like "System.out.", 
 * using Java SE5 or later Version static imports: 
 * Example : import static com.knightsoft.Print.print;
 * 
 * @version V1.0 Nov 08, 2008
 * @author Michael
 */
public class Print {
	// Print with a newline:
	public static void print(Object obj) {
		System.out.print(obj);
	}

	// Print a newline by itself:
	public static void print() {
		System.out.println();
	}

	// Print with no line break:
	public static void println(Object obj) {
		System.out.println(obj);
	}

	// The new Java SE5 printf() (from C):
	public static PrintStream printf(String format, Object... args) {
		return System.out.printf(format, args);
	}
}
